<template>
	<view class="page-wrap" :data-theme="theme" :class="theme" :style="globalColor.style">
		<TopBar :isOpeninstall="true" />
		<view class="download-wrap fboxCol Ycenter">
			<image class="bg" src="https://ebc-prod.cdn.benwunet.com/uni-static/h5/kd-b.png" mode="widthFix">
			<DownloadBtn :isOpeninstall="true" type="img" :img-url="imgUrl" img-style="width:326rpx;height:137rpx;margin: 0 0 58rpx" ref="download_btn" />
			<!-- <view class="btn color-fff font30 fboxRow Ycenter Xcenter" @click="goCopy" v-else>
				点击复制链接在浏览器中打开
			</view> -->
		</view>
	</view>
</template>

<script>
	import DownloadBtn from '@/components/download-btn-h5/download_btn.vue';
	import TopBar from '@/components/top-bar/index.vue';
	export default {
		components: {
			DownloadBtn,
			TopBar
		},
		data() {
			return {
				theme: getApp().globalData.appTheme,
				globalColor: getApp().globalData.globalColor,
				isApplet: false,
				imgUrl: 'https://ebc-prod.cdn.benwunet.com/uni-static/h5/kd-d.png'
			}
		},
		onLoad(option) {
			console.log(option)
			if(option && option.isApplet){
				this.isApplet = true;
			}
		},
		methods: {
			goCopy(){
				uni.setClipboardData({
					data: 'hello',
					success: function () {
						console.log('success');
					}
				});
			}
		}
	}
</script>

<style lang="scss" scoped>
    .download-wrap {
        min-height: calc(100vh);
        background: #fff no-repeat top center;
        /* background: #fff url("~@/assets/img/bg-download.jpg") no-repeat top center; */
        background-size: 750rpx 100%;
    }
    .bg {
        width: 750rpx;
        height: auto;
    }
    .logo {
        padding: 30rpx 0;
        width: 112rpx;
        height: 120rpx;
    }

    .logo img {
        width: 112rpx;
        height: 120rpx;
    }

    .download-wrap .title {
        margin-top: 50rpx;
        padding: 0 38rpx;
        color: #09363c;
        line-height: 60rpx;
    }

    .download-wrap .btn {
        position: fixed;
        bottom: 60rpx;
        left: 50%;
        transform: translateX(-50%);
        width: 560rpx;
        height: 88rpx;
        background: #f0bd42;
        box-shadow: 0px 0px 30rpx 0px rgba(13, 32, 2, 0.2);
        border-radius: 44rpx;
        cursor: pointer;
        border:0 none;
    }
    .space {
        height: 200rpx;
    }

    .QrCode {
        width: 570rpx;
        height: 556rpx;
        background-color: #fff;
        overflow: hidden;
        border-radius: 28rpx;
    }

    .QrCode .bd {
        margin: 50rpx 0 30rpx;
    }

    .QrCode .code {
        width: 300rpx;
        height: 300rpx;
        overflow: hidden;
    }

    .color-2E2E33 {
        color: #2e2e33;
    }

    .color-8B8B99 {
        color: #8b8b99;
    }

    .download-wrap ::v-deep .van-popup {
        background: none;
    }

    .close {
        margin-top: 60rpx;
    }

    .close .bksIcon {
        font-size: 60rpx;
    }
</style>